package com.deng.performance.first.view
{
	import com.deng.common.vo.EmployeeVo;
	
	import mx.controls.Label;
	import mx.events.FlexEvent;

	public class Pay_ValueLB extends Label
	{
		private var pvo:EmployeeVo;
		public function Pay_ValueLB()
		{
			this.addEventListener(FlexEvent.CREATION_COMPLETE,showHandler);
			this.addEventListener(FlexEvent.SHOW,showHandler);			
			super();
		}
		private function showHandler(event:FlexEvent):void{
			this.setStyle("fontWeight","bold");
			pvo = this.data as EmployeeVo;
			if(pvo.valid == 1){
				this.text = pvo.pay_value;
			}else{
				this.text = (new Number(pvo.pay_gongzuojixiao)+
							new Number(pvo.pay_jingyingjixiao)+
							new Number(pvo.zhiweijintie)+
							new Number(pvo.zerenjintie)+
							new Number(pvo.yuanlingjintie))+"";
			}
			
			
		}
	}
}